import React, { useEffect, useState } from 'react'
import { View,Image, Text } from '@tarojs/components'
import Taro from '@tarojs/taro'

import './index.scss'

export default function ActivityList() {
  const [list, setlist] = useState([])

  ////       network
  
  return (
    <View className="activity-list">
      {list.length?
      <View className="var-empty" v-if="!list.length">
        <Image src={require('@/static/empty.png')} mode="widthFix" style="width: 50vw;"></Image>
      </View>:null}
      {list.map(item=>{
        return <View className="list-item" key={item.id}>
        <View className="item-main">
          <Image className="main-img" src="https://img1.baidu.com/it/u=3486651663,3991438881&fm=253&fmt=auto&app=138&f=JPEG?w=500&h=500" mode="aspectFill"></Image>
          <View className="main-info">
            <View className="dot2 h2">活动标题-去挽救地球附近ask烦死了开发设计噶是否</View>
            <View className='p'>下周五 12:00</View>
            <View className='p'>北京店</View>
          </View>
        </View>
        <View className="item-footer">
          订单金额 <Text style="font-size: 20rpx;">￥</Text> <Text className='strong' style="font-size: 32rpx; margin-right: auto;">45.9</Text>
          <View className="footer-cancel button" onClick={()=>{

          }}>取消活动</View>
        </View>
      </View>
      })}
    </View>
  )
}
